package com.bestcem.xm.user.service.third;

import com.bestcem.xm.common.core.domain.web.ServiceResult;
import com.bestcem.xm.user.grpc.client.dto.PackageDTO;
import com.bestcem.xm.user.service.dto.user.GrowingioDTO;
import com.bestcem.xm.user.service.dto.user.OrganizationDTO;
import com.bestcem.xm.user.service.dto.user.UserDTO;

/**
 * 百度营销服务类
 * API文档地址: https://dev2.baidu.com/content?sceneType=0&pageId=101211&nodeId=658&subhead=2.4%20%E8%81%94%E8%B0%83
 *
 * @author wangyunyun <yunyun.wang@idiaoyan.com>
 * @version v1.0
 * @date 2022/3/1 14:30
 */
public interface GrowingIOService {

    /**
     * 获取growingio 数据对象UserProperty
     *
     * @param userDTO
     * @param organizationDTO
     * @param packageName
     * @return
     */
    GrowingioDTO getUserProperty(UserDTO userDTO, OrganizationDTO organizationDTO, String packageName);

    /**
     * growingio上传登陆用户变量
     *
     * @param growingioDTO growingio数据
     * @return ServiceResult<String>
     * @author wangyunyun <yunyun.wang@idiaoyan.com>
     * @date 2022/5/31 11:06
     */
    ServiceResult<String> uploadUserProperty(GrowingioDTO growingioDTO);

    /**
     * 上传用户变量信息到growingio
     *
     * @param userDTO         用户
     * @param organizationDTO 公司
     * @param packageDTO      套餐
     * @return ServiceResult<Void>
     * @author wangyunyun <yunyun.wang@idiaoyan.com>
     * @date 2022/5/31 16:50
     */
    ServiceResult<Void> uploadGrowingio(UserDTO userDTO, OrganizationDTO organizationDTO, PackageDTO packageDTO);
}
